struct Motor <: AbstractDevice end

function set_position(m::Device{Motor}, pos)
    @ccall lib.wb_motor_set_position(m.tag::Ptr{WbDeviceTag}, pos::Cdouble)::Cvoid
end

function set_velocity(m::Device{Motor}, velocity)
    @ccall lib.wb_motor_set_velocity(m.tag::Ptr{WbDeviceTag}, velocity::Cdouble)::Cvoid
end

function set_acceleration(m::Device{Motor}, acceleration)
    @ccall lib.wb_motor_set_acceleration(m.tag::Ptr{WbDeviceTag}, acceleration::Cdouble)::Cvoid
end

function set_available_force(m::Device{Motor}, force)
    @ccall lib.wb_motor_set_available_force(m.tag::Ptr{WbDeviceTag}, force::Cdouble)::Cvoid
end

function set_available_torque(m::Device{Motor}, torque)
    @ccall lib.wb_motor_set_available_torque(m.tag::Ptr{WbDeviceTag}, torque::Cdouble)::Cvoid
end

function set_control_pid(m::Device{Motor}, p, i, d)
    @ccall lib.wb_motor_set_pid(m.tag::Ptr{WbDeviceTag}, p::Cdouble, i::Cdouble, d::Cdouble)::Cvoid
end

function target_position(m::Device{Motor})
    @ccall lib.wb_motor_get_target_position(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function min_position(m::Device{Motor})
    @ccall lib.wb_motor_get_min_position(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function max_position(m::Device{Motor})
    @ccall lib.wb_motor_get_max_position(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function velocity(m::Device{Motor})
    @ccall lib.wb_motor_get_velocity(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function max_velocity(m::Device{Motor})
    @ccall lib.wb_motor_get_max_velocity(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function acceleration(m::Device{Motor})
    @ccall lib.wb_motor_get_acceleration(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function available_force(m::Device{Motor})
    @ccall lib.wb_motor_get_available_force(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function max_force(m::Device{Motor})
    @ccall lib.wb_motor_get_max_force(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function available_torque(m::Device{Motor})
    @ccall lib.wb_motor_get_available_torque(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function max_torque(m::Device{Motor})
    @ccall lib.wb_motor_get_max_torque(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function multiplier(m::Device{Motor})
    @ccall lib.wb_motor_get_multiplier(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function enable_force_feedback(m::Device{Motor}, sampling_period)
    @ccall wb_motor_enable_force_feedback(m.tag::Ptr{WbDeviceTag}, sampling_period::Cint)::Cvoid
end

function disable_force_feedback(m::Device{Motor})
    @ccall wb_motor_disable_force_feedback(m.tag::Ptr{WbDeviceTag})::Cvoid
end

function force_feedback(m::Device{Motor})
    @ccall wb_motor_get_force_feedback(m.tag::Ptr{WbDeviceTag})::Cvoid
end

function force_feedback_sampling_period(m::Device{Motor})
    @ccall wb_motor_get_force_feedback_sampling_period(m.tag::Ptr{WbDeviceTag})::Cint
end

function enable_torque_feedback(m::Device{Motor}, sampling_period)
    @ccall wb_motor_enable_torque_feedback(m.tag::Ptr{WbDeviceTag}, sampling_period::Cint)::Cvoid
end

function disable_torque_feedback(m::Device{Motor})
    @ccall wb_motor_disable_torque_feedback(m.tag::Ptr{WbDeviceTag})::Cvoid
end

function torque_feedback(m::Device{Motor})
    @ccall wb_motor_get_torque_feedback(m.tag::Ptr{WbDeviceTag})::Cdouble
end

function torque_feedback_sampling_period(m::Device{Motor})
    @ccall wb_motor_get_torque_feedback_sampling_period(m.tag::Ptr{WbDeviceTag})::Cint
end

function set_force(m::Device{Motor}, force)
    @ccall lib.wb_motor_set_force(m.tag::Ptr{WbDeviceTag}, force::Cdouble)::Cvoid
end

function set_torque(m::Device{Motor}, torque)
    @ccall lib.wb_motor_set_torque(m.tag::Ptr{WbDeviceTag}, torque::Cdouble)::Cvoid
end

